﻿@model Senac.Escola.Projeto.Models.Categoria

@{
    ViewBag.Title = "Create";
}

<h2>Criar</h2>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@using (Html.BeginForm()) {
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>Categoria</legend>

        <div class="editor-label">
            @Html.LabelFor(model => model.Nome)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Nome)
            @Html.ValidationMessageFor(model => model.Nome)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Descricao)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Descricao)
            @Html.ValidationMessageFor(model => model.Descricao)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.ProfessorID, "Professor")
        </div>
        <div class="editor-field">
            @Html.DropDownList("ProfessorID", String.Empty)
            @Html.ValidationMessageFor(model => model.ProfessorID)
        </div>

        <p>
            <input class="btn btn-danger"type="submit" value="Create" />
        </p>
    </fieldset>
}

